<!-- templates/modal.html -->
<div class="modal fade" id="addFormModal" tabindex="-1" aria-labelledby="Label" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">新增模型</h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
            </div>
            <div class="modal-body">
                <form id="addForm">
                    <div class="mb-3">
                        <label for="add_title" class="form-label">模型名:</label>
                        <input type="text" class="form-control" id="add_title" name="add_title" required>
                    </div>
                    <div class="mb-3">
                        <label for="add_sub_title" class="form-label">模型说明:</label>
                        <textarea class="form-control" id="add_sub_title" name="add_sub_title"></textarea>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">取消</button>
                <button type="button" class="btn btn-primary" id="submitAddForm" onclick="submitForm('addForm')">确认</button>
            </div>
        </div>
    </div>
</div>


<div class="modal fade" id="modifyFormModal" tabindex="-1" aria-labelledby="Label" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">修改模型</h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
            </div>
            <div class="modal-body">
                <form id="modifyForm">
                    <div class="mb-3">
                        <label for="old_title" class="form-label">旧模型名:</label>
                        <input type="text" class="form-control" id="old_title" name="old_title" readonly>
                    </div>
                    <div class="mb-3">
                        <label for="modify_title" class="form-label">新模型名:</label>
                        <input type="text" class="form-control" id="modify_title" name="modify_title" required>
                    </div>
                    <div class="mb-3">
                        <label for="modify_sub_title" class="form-label">模型说明:</label>
                        <textarea class="form-control" id="modify_sub_title" name="modify_sub_title"></textarea>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">取消</button>
                <button type="button" class="btn btn-primary" id="submitModifyForm" onclick="submitForm('modifyForm')">确认</button>
            </div>
        </div>
    </div>
</div>


<div class="modal fade" id="deleteFormModal" tabindex="-1" aria-labelledby="Label" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">删除模型</h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
            </div>
            <div class="modal-body">
                <form id="deleteForm">
                    <div class="mb-3">
                        <label for="delete_title" class="form-label">模型名:</label>
                        <input type="text" class="form-control" id="delete_title" name="delete_title" required readonly>
                    </div>
                    <div class="mb-3">
                        <label for="delete_sub_title" class="form-label">模型说明:</label>
                        <textarea class="form-control" id="delete_sub_title" name="delete_sub_title" readonly></textarea>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">取消</button>
                <button type="button" class="btn btn-primary" id="submitDeleteForm" onclick="submitForm('deleteForm')">确认</button>
            </div>
        </div>
    </div>
</div>


<div class="modal fade" id="refreshDataModal" tabindex="-1" aria-labelledby="Label" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">刷新数据</h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
            </div>
            <div class="modal-body">
                <form id="refreshData">
                    <div class="mb-3">
                        <label class="form-label">重新扫描本地数据文件，并更新数据详情表？</label>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">取消</button>
                <button type="button" class="btn btn-primary" id="submitRefreshData" onclick="submitForm('refreshData')">确认</button>
            </div>
        </div>
    </div>
</div>

